home *** CD-ROM | disk | FTP | other *** search
/ Garbo / Garbo.cdr / mac / hypercrd / hc2_x / tcprogud.sit / TC Prog Guide / card_28174.txt < prev    next >
Text File  |  1991-02-27  |  2KB  |  30 lines

  1. -- card: 28174 from stack: in
  2. -- bmap block id: 0
  3. -- flags: 0000
  4. -- background id: 4755
  5. -- name: 
  6.  
  7.  
  8. -- part contents for background part 4
  9. ----- text -----
  10. declaration simply identifies the thing so the compiler is not confused.  The personnel _rec struct expression discussed earlier* may be thought of as "declaring" the types of its members, since no space is yet allocated for these variables.  However, we say the struct expression "defines" the new personnel_rec type by describing its structure.
  11.  
  12. When a variable is declared in the body of a function (block scope), it has the AUTOMATIC storage class by default.  Space for such a variable is automatically allocated upon declaration - meaning that the declaration also serves as a definition - and deallocated upon exit from this function.  If the function is called again at a later time, the value contained in this variable is generally NOT the value remaining after the previous call.  (The declarations of some automatic variables may be preceded with the 'register' specifier.  This may speed access by using one of the machine's high-speed registers instead of standard memory.  The number of registers available and the data types allowed are machine-dependent.  Standard memory will be used if no appropriate register is available.)
  13.  
  14. When a variable is declared outside the body of a function (file scope), it has the STATIC storage class by default.  Space for such a variable is allocated at the start of 
  15.  
  16. -- part contents for background part 29
  17. ----- text -----
  18. 25150
  19.  
  20. -- part contents for background part 27
  21. ----- text -----
  22. personnel_rec structure
  23.  
  24. -- part contents for background part 20
  25. ----- text -----
  26. personnel_rec structure - p66
  27.  
  28. -- part contents for background part 7
  29. ----- text -----
  30. 77